<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

/**
 * 用户个人信息扩展表
 *
 * Date: 19/03/2018
 * @author George
 */
class CreatePersonalsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('personals', function (Blueprint $table) {
			$table->string('identification', 18)->primary()->comment('身份证');
			$table->unsignedTinyInteger('stature')->default(0)->comment('身高');
			$table->unsignedTinyInteger('weight')->default(0)->comment('体重');
			$table->string('education')->nullable()->comment('学历');
			$table->string('address')->nullable()->comment('现居地址');
			$table->string('marital')->nullable()->comment('婚姻状况');
			$table->string('urgency_name')->default('')->comment('紧急联系人');
			$table->string('urgency_mobile')->default('')->comment('紧急联系人手机');
			$table->string('urgency_relation')->default('')->comment('紧急联系人关系');
			$table->json('trade')->nullable()->comment('行业');
			$table->json('skill')->nullable()->comment('技能');
			$table->json('channel')->nullable()->comment('应聘渠道');
			$table->string('debit')->nullable()->comment('银行卡号');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('personals');
    }
}
